﻿using System;


class MinMaxNumbers
{
    static void Main(string[] args)
    {
        Console.Write("Enter n= ");
        int n = int.Parse(Console.ReadLine());
        int[] arr = new int[n];
        int max = 0;
        int min = 0;

        for (int i = 0; i <= n - 1; i++)
        {
            arr[i] = int.Parse(Console.ReadLine());
            if (i == 0)
            {
                min = arr[i];
                max = arr[i];
            }
            if (arr[i] > max)
            {
                max = arr[i];
            }
            if (arr[i] < min)
            {
                min = arr[i];
            }
        }
        Console.WriteLine("The min number from the sequence is {0}", min);
        Console.WriteLine("The max number from the sequence is {0}", max);

    }

}
